<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>用户中心</title>
<include file="public:header" />
</head>
<body>
<div id="header" class="layui-bg-cyan">
	<div class="layui-container">
		<div class="fl">
			<li class="nav-item active"><a href="/" class="nav-link">返回</a></li>
		</div>
		<div class="fr">
			<li class="nav-item"><a href="/user/index" class="nav-link"><img src="{$data.avatar}" alt="{$data.nickname}">{$data.nickname|default=$data.name}</a>
		</div>
	</div>
</div>
<div id="content">
	<div class="layui-clear" ></div>
	<div class="layui-container">
		<div class="layui-row layui-col-space30">
			<div class="layui-col-md3">

				<div class="layui-card">
					<div class="layui-card-header layui-bg-cyan">导航</div>
					<div class="layui-card-body" id="userNav" >
						<include file="/user/userNav">
					</div>				
				</div>		   
		    </div>
		    <div class="layui-col-md9">

				<div class="layui-card" >
					<div class="layui-card-header layui-bg-cyan">APP ID</div>
					<div class="layui-card-body" style="overflow:hidden;" >
						
						<notempty name="$data.app_id">
							<div class="layui-form">
								<div class="layui-form-item">
									<label class="layui-form-label">app_id：</label>
									<div class="layui-input-block">
									 	<div class="layui-form-mid layui-word-aux">{$data.app_id}</div>
									</div>			
									<label class="layui-form-label">app_secret：</label>
									<div class="layui-input-block">
									  <div class="layui-form-mid layui-word-aux">{$data.app_secret}</div>
									</div>						
								</div>
								<div class="layui-form-item">
									<button type="submit" class="layui-btn layui-btn-normal" lay-ajax="" lay-url="/user/appid" lay-reload="true" >更换APPKEY</button>
								</div>
							</div>
						<else/>
							<div class="layui-form">
								<div class="layui-form-item">
									<div class="layui-input-block">
									 	<div class="layui-form-mid layui-word-aux">还没有生成appKey,请点击按钮生成！</div>
									</div>								
								</div>

								<div class="layui-form-item">
									<button type="submit" class="layui-btn layui-btn-normal" lay-ajax="" lay-url="/user/appid" lay-reload="true">生成APPKEY</button>
								</div>
							</div>
						</notempty>	
					</div>
				</div>
			</div>		    			
		</div>
	</div>
</div>
<include file="public:footer"/>
</body>
